pub fn dp_rec_mc(mut amount: u32) -> u32 {
    const CASHES: [u32; 8] = [1, 2, 5, 10, 20, 30, 50, 100];
    let mut res = 0;
    for &cash in CASHES.iter().rev() {
        res += amount / cash;
        amount = amount % cash;
        if amount == 0 { break; }
    }
    res
}
